package Utils;

import com.github.houbb.sensitive.word.bs.SensitiveWordBs;

public class wordsFilterUtil {
    public static String wordsCheck(String str){
        boolean contains = SensitiveWordBs.newInstance().contains(str);
        if (contains){
            String first = SensitiveWordBs.newInstance().findFirst(str);
            System.out.println(first);
            return first;
        }else {
            return "";
        }
    }

    public static void main(String[] args) {
        wordsCheck("这是一条色情数据");
    }
}
